Integrand size = 18, antiderivative size = 169 \[ \int \frac {\left (a+b \sin \left (c+d x^2\right )\right )^2}{x^5} \, dx=-\frac {2 a^2+b^2}{8 x^4}-\frac {a b d \cos \left (c+d x^2\right )}{2 x^2}+\frac {b^2 \cos \left (2 \left (c+d x^2\right )\right )}{8 x^4}+\frac {1}{2} b^2 d^2 \cos (2 c) \operatorname {CosIntegral}\left (2 d x^2\right )-\frac {1}{2} a b d^2 \operatorname {CosIntegral}\left (d x^2\right ) \sin (c)-\frac {a b \sin \left (c+d x^2\right )}{2 x^4}-\frac {b^2 d \sin \left (2 \left (c+d x^2\right )\right )}{4 x^2}-\frac {1}{2} a b d^2 \cos (c) \text {Si}\left (d x^2\right )-\frac {1}{2} b^2 d^2 \sin (2 c) \text {Si}\left (2 d x^2\right ) \]
1/8*(-2*a^2-b^2)/x^4+1/2*b^2*d^2*Ci(2*d*x^2)*cos(2*c)-1/2*a*b*d*cos(d*x^2+ c)/x^2+1/8*b^2*cos(2*d*x^2+2*c)/x^4-1/2*a*b*d^2*cos(c)*Si(d*x^2)-1/2*a*b*d ^2*Ci(d*x^2)*sin(c)-1/2*b^2*d^2*Si(2*d*x^2)*sin(2*c)-1/2*a*b*sin(d*x^2+c)/ x^4-1/4*b^2*d*sin(2*d*x^2+2*c)/x^2
Time = 0.31 (sec) , antiderivative size = 158, normalized size of antiderivative = 0.93 \[ \int \frac {\left (a+b \sin \left (c+d x^2\right )\right )^2}{x^5} \, dx=-\frac {2 a^2+b^2+4 a b d x^2 \cos \left (c+d x^2\right )-b^2 \cos \left (2 \left (c+d x^2\right )\right )-4 b^2 d^2 x^4 \cos (2 c) \operatorname {CosIntegral}\left (2 d x^2\right )+4 a b d^2 x^4 \operatorname {CosIntegral}\left (d x^2\right ) \sin (c)+4 a b \sin \left (c+d x^2\right )+2 b^2 d x^2 \sin \left (2 \left (c+d x^2\right )\right )+4 a b d^2 x^4 \cos (c) \text {Si}\left (d x^2\right )+4 b^2 d^2 x^4 \sin (2 c) \text {Si}\left (2 d x^2\right )}{8 x^4} \]
-1/8*(2*a^2 + b^2 + 4*a*b*d*x^2*Cos[c + d*x^2] - b^2*Cos[2*(c + d*x^2)] - 4*b^2*d^2*x^4*Cos[2*c]*CosIntegral[2*d*x^2] + 4*a*b*d^2*x^4*CosIntegral[d* x^2]*Sin[c] + 4*a*b*Sin[c + d*x^2] + 2*b^2*d*x^2*Sin[2*(c + d*x^2)] + 4*a* b*d^2*x^4*Cos[c]*SinIntegral[d*x^2] + 4*b^2*d^2*x^4*Sin[2*c]*SinIntegral[2 *d*x^2])/x^4
Time = 0.50 (sec) , antiderivative size = 169, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {3884, 6, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {\left (a+b \sin \left (c+d x^2\right )\right )^2}{x^5} \, dx\) |
\(\Big \downarrow \) 3884 |
\(\displaystyle \int \left (\frac {a^2}{x^5}+\frac {2 a b \sin \left (c+d x^2\right )}{x^5}-\frac {b^2 \cos \left (2 c+2 d x^2\right )}{2 x^5}+\frac {b^2}{2 x^5}\right )dx\) |
\(\Big \downarrow \) 6 |
\(\displaystyle \int \left (\frac {a^2+\frac {b^2}{2}}{x^5}+\frac {2 a b \sin \left (c+d x^2\right )}{x^5}-\frac {b^2 \cos \left (2 c+2 d x^2\right )}{2 x^5}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {2 a^2+b^2}{8 x^4}-\frac {1}{2} a b d^2 \sin (c) \operatorname {CosIntegral}\left (d x^2\right )-\frac {1}{2} a b d^2 \cos (c) \text {Si}\left (d x^2\right )-\frac {a b d \cos \left (c+d x^2\right )}{2 x^2}-\frac {a b \sin \left (c+d x^2\right )}{2 x^4}+\frac {1}{2} b^2 d^2 \cos (2 c) \operatorname {CosIntegral}\left (2 d x^2\right )-\frac {1}{2} b^2 d^2 \sin (2 c) \text {Si}\left (2 d x^2\right )-\frac {b^2 d \sin \left (2 \left (c+d x^2\right )\right )}{4 x^2}+\frac {b^2 \cos \left (2 \left (c+d x^2\right )\right )}{8 x^4}\) |
-1/8*(2*a^2 + b^2)/x^4 - (a*b*d*Cos[c + d*x^2])/(2*x^2) + (b^2*Cos[2*(c + d*x^2)])/(8*x^4) + (b^2*d^2*Cos[2*c]*CosIntegral[2*d*x^2])/2 - (a*b*d^2*Co sIntegral[d*x^2]*Sin[c])/2 - (a*b*Sin[c + d*x^2])/(2*x^4) - (b^2*d*Sin[2*( c + d*x^2)])/(4*x^2) - (a*b*d^2*Cos[c]*SinIntegral[d*x^2])/2 - (b^2*d^2*Si n[2*c]*SinIntegral[2*d*x^2])/2
3.1.17.3.1 Defintions of rubi rules used
Int[(u_.)*((v_.) + (a_.)*(Fx_) + (b_.)*(Fx_))^(p_.), x_Symbol] :> Int[u*(v + (a + b)*Fx)^p, x] /; FreeQ[{a, b}, x] && !FreeQ[Fx, x]
Int[((e_.)*(x_))^(m_.)*((a_.) + (b_.)*Sin[(c_.) + (d_.)*(x_)^(n_)])^(p_), x _Symbol] :> Int[ExpandTrigReduce[(e*x)^m, (a + b*Sin[c + d*x^n])^p, x], x] /; FreeQ[{a, b, c, d, e, m}, x] && IGtQ[p, 1] && IGtQ[n, 0]
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 0.68 (sec) , antiderivative size = 271, normalized size of antiderivative = 1.60
method | result | size |
risch | \(\frac {2 i {\mathrm e}^{-2 i c} \pi \,\operatorname {csgn}\left (d \,x^{2}\right ) b^{2} d^{2} x^{4}+2 \pi \,\operatorname {csgn}\left (d \,x^{2}\right ) {\mathrm e}^{-i c} a b \,d^{2} x^{4}-4 i {\mathrm e}^{-2 i c} \operatorname {Si}\left (2 d \,x^{2}\right ) b^{2} d^{2} x^{4}-2 i a b \,d^{2} \operatorname {Ei}_{1}\left (-i d \,x^{2}\right ) {\mathrm e}^{i c} x^{4}+2 i \operatorname {Ei}_{1}\left (-i d \,x^{2}\right ) {\mathrm e}^{-i c} a b \,d^{2} x^{4}-4 \,\operatorname {Si}\left (d \,x^{2}\right ) {\mathrm e}^{-i c} a b \,d^{2} x^{4}-2 \,{\mathrm e}^{-2 i c} \operatorname {Ei}_{1}\left (-2 i d \,x^{2}\right ) b^{2} d^{2} x^{4}-2 b^{2} d^{2} \operatorname {Ei}_{1}\left (-2 i d \,x^{2}\right ) {\mathrm e}^{2 i c} x^{4}-4 a b \,x^{2} \cos \left (d \,x^{2}+c \right ) d -2 b^{2} x^{2} \sin \left (2 d \,x^{2}+2 c \right ) d -4 \sin \left (d \,x^{2}+c \right ) a b +b^{2} \cos \left (2 d \,x^{2}+2 c \right )-2 a^{2}-b^{2}}{8 x^{4}}\) | \(271\) |
1/8*(2*I*exp(-2*I*c)*Pi*csgn(d*x^2)*b^2*d^2*x^4+2*Pi*csgn(d*x^2)*exp(-I*c) *a*b*d^2*x^4-4*I*exp(-2*I*c)*Si(2*d*x^2)*b^2*d^2*x^4-2*I*a*b*d^2*Ei(1,-I*d *x^2)*exp(I*c)*x^4+2*I*Ei(1,-I*d*x^2)*exp(-I*c)*a*b*d^2*x^4-4*Si(d*x^2)*ex p(-I*c)*a*b*d^2*x^4-2*exp(-2*I*c)*Ei(1,-2*I*d*x^2)*b^2*d^2*x^4-2*b^2*d^2*E i(1,-2*I*d*x^2)*exp(2*I*c)*x^4-4*a*b*x^2*cos(d*x^2+c)*d-2*b^2*x^2*sin(2*d* x^2+2*c)*d-4*sin(d*x^2+c)*a*b+b^2*cos(2*d*x^2+2*c)-2*a^2-b^2)/x^4
Time = 0.28 (sec) , antiderivative size = 156, normalized size of antiderivative = 0.92 \[ \int \frac {\left (a+b \sin \left (c+d x^2\right )\right )^2}{x^5} \, dx=\frac {2 \, b^{2} d^{2} x^{4} \cos \left (2 \, c\right ) \operatorname {Ci}\left (2 \, d x^{2}\right ) - 2 \, a b d^{2} x^{4} \operatorname {Ci}\left (d x^{2}\right ) \sin \left (c\right ) - 2 \, b^{2} d^{2} x^{4} \sin \left (2 \, c\right ) \operatorname {Si}\left (2 \, d x^{2}\right ) - 2 \, a b d^{2} x^{4} \cos \left (c\right ) \operatorname {Si}\left (d x^{2}\right ) - 2 \, a b d x^{2} \cos \left (d x^{2} + c\right ) + b^{2} \cos \left (d x^{2} + c\right )^{2} - a^{2} - b^{2} - 2 \, {\left (b^{2} d x^{2} \cos \left (d x^{2} + c\right ) + a b\right )} \sin \left (d x^{2} + c\right )}{4 \, x^{4}} \]
1/4*(2*b^2*d^2*x^4*cos(2*c)*cos_integral(2*d*x^2) - 2*a*b*d^2*x^4*cos_inte gral(d*x^2)*sin(c) - 2*b^2*d^2*x^4*sin(2*c)*sin_integral(2*d*x^2) - 2*a*b* d^2*x^4*cos(c)*sin_integral(d*x^2) - 2*a*b*d*x^2*cos(d*x^2 + c) + b^2*cos( d*x^2 + c)^2 - a^2 - b^2 - 2*(b^2*d*x^2*cos(d*x^2 + c) + a*b)*sin(d*x^2 + c))/x^4
\[ \int \frac {\left (a+b \sin \left (c+d x^2\right )\right )^2}{x^5} \, dx=\int \frac {\left (a + b \sin {\left (c + d x^{2} \right )}\right )^{2}}{x^{5}}\, dx \]
Result contains complex when optimal does not.
Time = 0.36 (sec) , antiderivative size = 128, normalized size of antiderivative = 0.76 \[ \int \frac {\left (a+b \sin \left (c+d x^2\right )\right )^2}{x^5} \, dx=\frac {1}{2} \, {\left ({\left (i \, \Gamma \left (-2, i \, d x^{2}\right ) - i \, \Gamma \left (-2, -i \, d x^{2}\right )\right )} \cos \left (c\right ) + {\left (\Gamma \left (-2, i \, d x^{2}\right ) + \Gamma \left (-2, -i \, d x^{2}\right )\right )} \sin \left (c\right )\right )} a b d^{2} - \frac {{\left (4 \, {\left ({\left (\Gamma \left (-2, 2 i \, d x^{2}\right ) + \Gamma \left (-2, -2 i \, d x^{2}\right )\right )} \cos \left (2 \, c\right ) + {\left (-i \, \Gamma \left (-2, 2 i \, d x^{2}\right ) + i \, \Gamma \left (-2, -2 i \, d x^{2}\right )\right )} \sin \left (2 \, c\right )\right )} d^{2} x^{4} + 1\right )} b^{2}}{8 \, x^{4}} - \frac {a^{2}}{4 \, x^{4}} \]
1/2*((I*gamma(-2, I*d*x^2) - I*gamma(-2, -I*d*x^2))*cos(c) + (gamma(-2, I* d*x^2) + gamma(-2, -I*d*x^2))*sin(c))*a*b*d^2 - 1/8*(4*((gamma(-2, 2*I*d*x ^2) + gamma(-2, -2*I*d*x^2))*cos(2*c) + (-I*gamma(-2, 2*I*d*x^2) + I*gamma (-2, -2*I*d*x^2))*sin(2*c))*d^2*x^4 + 1)*b^2/x^4 - 1/4*a^2/x^4
Leaf count of result is larger than twice the leaf count of optimal. 448 vs. \(2 (153) = 306\).
Time = 0.30 (sec) , antiderivative size = 448, normalized size of antiderivative = 2.65 \[ \int \frac {\left (a+b \sin \left (c+d x^2\right )\right )^2}{x^5} \, dx=\frac {4 \, {\left (d x^{2} + c\right )}^{2} b^{2} d^{3} \cos \left (2 \, c\right ) \operatorname {Ci}\left (2 \, d x^{2}\right ) - 8 \, {\left (d x^{2} + c\right )} b^{2} c d^{3} \cos \left (2 \, c\right ) \operatorname {Ci}\left (2 \, d x^{2}\right ) + 4 \, b^{2} c^{2} d^{3} \cos \left (2 \, c\right ) \operatorname {Ci}\left (2 \, d x^{2}\right ) - 4 \, {\left (d x^{2} + c\right )}^{2} a b d^{3} \operatorname {Ci}\left (d x^{2}\right ) \sin \left (c\right ) + 8 \, {\left (d x^{2} + c\right )} a b c d^{3} \operatorname {Ci}\left (d x^{2}\right ) \sin \left (c\right ) - 4 \, a b c^{2} d^{3} \operatorname {Ci}\left (d x^{2}\right ) \sin \left (c\right ) - 4 \, {\left (d x^{2} + c\right )}^{2} a b d^{3} \cos \left (c\right ) \operatorname {Si}\left (d x^{2}\right ) + 8 \, {\left (d x^{2} + c\right )} a b c d^{3} \cos \left (c\right ) \operatorname {Si}\left (d x^{2}\right ) - 4 \, a b c^{2} d^{3} \cos \left (c\right ) \operatorname {Si}\left (d x^{2}\right ) + 4 \, {\left (d x^{2} + c\right )}^{2} b^{2} d^{3} \sin \left (2 \, c\right ) \operatorname {Si}\left (-2 \, d x^{2}\right ) - 8 \, {\left (d x^{2} + c\right )} b^{2} c d^{3} \sin \left (2 \, c\right ) \operatorname {Si}\left (-2 \, d x^{2}\right ) + 4 \, b^{2} c^{2} d^{3} \sin \left (2 \, c\right ) \operatorname {Si}\left (-2 \, d x^{2}\right ) - 4 \, {\left (d x^{2} + c\right )} a b d^{3} \cos \left (d x^{2} + c\right ) + 4 \, a b c d^{3} \cos \left (d x^{2} + c\right ) - 2 \, {\left (d x^{2} + c\right )} b^{2} d^{3} \sin \left (2 \, d x^{2} + 2 \, c\right ) + 2 \, b^{2} c d^{3} \sin \left (2 \, d x^{2} + 2 \, c\right ) + b^{2} d^{3} \cos \left (2 \, d x^{2} + 2 \, c\right ) - 4 \, a b d^{3} \sin \left (d x^{2} + c\right ) - 2 \, a^{2} d^{3} - b^{2} d^{3}}{8 \, {\left ({\left (d x^{2} + c\right )}^{2} - 2 \, {\left (d x^{2} + c\right )} c + c^{2}\right )} d} \]
1/8*(4*(d*x^2 + c)^2*b^2*d^3*cos(2*c)*cos_integral(2*d*x^2) - 8*(d*x^2 + c )*b^2*c*d^3*cos(2*c)*cos_integral(2*d*x^2) + 4*b^2*c^2*d^3*cos(2*c)*cos_in tegral(2*d*x^2) - 4*(d*x^2 + c)^2*a*b*d^3*cos_integral(d*x^2)*sin(c) + 8*( d*x^2 + c)*a*b*c*d^3*cos_integral(d*x^2)*sin(c) - 4*a*b*c^2*d^3*cos_integr al(d*x^2)*sin(c) - 4*(d*x^2 + c)^2*a*b*d^3*cos(c)*sin_integral(d*x^2) + 8* (d*x^2 + c)*a*b*c*d^3*cos(c)*sin_integral(d*x^2) - 4*a*b*c^2*d^3*cos(c)*si n_integral(d*x^2) + 4*(d*x^2 + c)^2*b^2*d^3*sin(2*c)*sin_integral(-2*d*x^2 ) - 8*(d*x^2 + c)*b^2*c*d^3*sin(2*c)*sin_integral(-2*d*x^2) + 4*b^2*c^2*d^ 3*sin(2*c)*sin_integral(-2*d*x^2) - 4*(d*x^2 + c)*a*b*d^3*cos(d*x^2 + c) + 4*a*b*c*d^3*cos(d*x^2 + c) - 2*(d*x^2 + c)*b^2*d^3*sin(2*d*x^2 + 2*c) + 2 *b^2*c*d^3*sin(2*d*x^2 + 2*c) + b^2*d^3*cos(2*d*x^2 + 2*c) - 4*a*b*d^3*sin (d*x^2 + c) - 2*a^2*d^3 - b^2*d^3)/(((d*x^2 + c)^2 - 2*(d*x^2 + c)*c + c^2 )*d)
Timed out. \[ \int \frac {\left (a+b \sin \left (c+d x^2\right )\right )^2}{x^5} \, dx=\int \frac {{\left (a+b\,\sin \left (d\,x^2+c\right )\right )}^2}{x^5} \,d x \]